<!-- Footer -->
<footer>
    <div class="container">
        <div class="row">
            <div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">
                <ul class="list-inline text-center">
                   {{ if .Site.Params.social.rss }}
                   <li>
                       <a href='{{ with .OutputFormats.Get "RSS" }}{{ .RelPermalink }}{{ end }}' rel="alternate" type="application/rss+xml" title="{{ .Site.Title | default "" }}" >
                           <span class="fa-stack fa-lg">
                               <i class="fa fa-circle fa-stack-2x"></i>
                               <i class="fa fa-rss fa-stack-1x fa-inverse"></i>
                           </span>
                       </a>
                   </li>
                   {{ end }}
                    {{ with .Site.Params.social.email }}
                    <li>
                        <a href="mailto:{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-envelope fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
		    {{ end }}
                    
                    {{ with .Site.Params.social.twitter }}
                    <li>
                        <a href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-twitter fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
                    {{ end }}
                    {{ with .Site.Params.social.zhihu }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa  fa-stack-1x fa-inverse">知</i>
                            </span>
                        </a>
                    </li>
		    {{ end }}
                    {{ with .Site.Params.social.weibo }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-weibo fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
		    {{ end }}

                    {{ with .Site.Params.social.facebook }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-facebook fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
		    {{ end }}

		    <!-- Huabing: add wechat QR code link -->
                    {{ with .Site.Params.social.wechat }}
                    <li>
                        <a target="_blank" href="{{ . | relURL }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-wechat fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
		    {{ end }}
                    {{ with .Site.Params.social.github }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-github fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
		    {{ end }}
                    {{ with .Site.Params.social.gitlab }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-gitlab fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
            {{ end }}
                    {{ with .Site.Params.social.git }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-git fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
            {{ end }}
                    {{ with .Site.Params.social.linkedin }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-linkedin fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
		    {{ end }}
                    {{ with .Site.Params.social.medium }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-medium fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
            {{ end }}
                    {{ with .Site.Params.social.stackoverflow }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-stack-overflow fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
            {{ end }}
                    {{ with .Site.Params.social.reddit }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-reddit fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
            {{ end }}
                    {{ with .Site.Params.social.mastodon }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-mastodon fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
            {{ end }}
                    {{ with .Site.Params.social.keybase }}
                    <li>
                        <a target="_blank" href="{{ . }}">
                            <span class="fa-stack fa-lg">
                                <i class="fa fa-circle fa-stack-2x"></i>
                                <i class="fa fa-keybase fa-stack-1x fa-inverse"></i>
                            </span>
                        </a>
                    </li>
            {{ end }}
            {{ with .Site.Params.social.xing }}
            <li>
                <a target="_blank" href="{{ . }}">
                    <span class="fa-stack fa-lg">
                        <i class="fa fa-circle fa-stack-2x"></i>
                        <i class="fa fa-xing fa-stack-1x fa-inverse"></i>
                    </span>
                </a>
            </li>
            {{ end }}
            {{ with .Site.Params.social.instagram }}
            <li>
                <a target="_blank" href="{{ . }}">
                    <span class="fa-stack fa-lg">
                        <i class="fa fa-circle fa-stack-2x"></i>
                        <i class="fa fa-instagram fa-stack-1x fa-inverse"></i>
                    </span>
                </a>
            </li>
            {{ end }}
            {{ with .Site.Params.social.flickr }}
            <li>
                <a target="_blank" href="{{ . }}">
                    <span class="fa-stack fa-lg">
                        <i class="fa fa-circle fa-stack-2x"></i>
                        <i class="fa fa-flickr fa-stack-1x fa-inverse"></i>
                    </span>
                </a>
            </li>
    {{ end }}
                </ul>
		<p class="copyright text-muted">
                    Copyright &copy; {{ .Site.Title }} {{ now.Year }}
                    <br>
                    <a href="https://themes.gohugo.io/hugo-theme-cleanwhite">CleanWhite Hugo Theme</a> by <a href="https://zhaohuabing.com">Huabing</a> |
                    <iframe
                        style="margin-left: 2px; margin-bottom:-5px;"
                        frameborder="0" scrolling="0" width="100px" height="20px"
                        src="https://ghbtns.com/github-btn.html?user=zhaohuabing&repo=hugo-theme-cleanwhite&type=star&count=true" >
                    </iframe>
                </p>
            </div>
        </div>
    </div>
</footer>



<!-- async load function -->
<script>
    function async(u, c) {
      var d = document, t = 'script',
          o = d.createElement(t),
          s = d.getElementsByTagName(t)[0];
      o.src = u;
      if (c) { o.addEventListener('load', function (e) { c(null, e); }, false); }
      s.parentNode.insertBefore(o, s);
    }
</script>

<!-- 
     Because of the native support for backtick-style fenced code blocks 
     right within the Markdown is landed in Github Pages, 
     From V1.6, There is no need for Highlight.js, 
     so Huxblog drops it officially.

     - https://github.com/blog/2100-github-pages-now-faster-and-simpler-with-jekyll-3-0  
     - https://help.github.com/articles/creating-and-highlighting-code-blocks/    
-->
<!--
    <script>
        async("http://cdn.bootcss.com/highlight.js/8.6/highlight.min.js", function(){
            hljs.initHighlightingOnLoad();
        })
    </script>
    <link href="http://cdn.bootcss.com/highlight.js/8.6/styles/github.min.css" rel="stylesheet">
-->


<!-- jquery.tagcloud.js -->
<script>
    // only load tagcloud.js in tag.html
    if($('#tag_cloud').length !== 0){
        async("/js/jquery.tagcloud.js",function(){
            $.fn.tagcloud.defaults = {
                //size: {start: 1, end: 1, unit: 'em'},
                color: {start: '#bbbbee', end: '#0085a1'},
            };
            $('#tag_cloud a').tagcloud();
        })
    }
</script>

<!--fastClick.js -->
<script>
    async("https://cdnjs.cloudflare.com/ajax/libs/fastclick/1.0.6/fastclick.js", function(){
        var $nav = document.querySelector("nav");
        if($nav) FastClick.attach($nav);
    })
</script>

<!-- push page to Baidu -->
{{ if .Site.Params.ba_track_id }}
<script>
    (function(){
        var bp = document.createElement('script');
        var curProtocol = window.location.protocol.split(':')[0];
        if (curProtocol === 'https'){
       bp.src = 'https://zz.bdstatic.com/linksubmit/push.js';
      }
      else{
      bp.src = 'http://push.zhanzhang.baidu.com/push.js';
      }
        var s = document.getElementsByTagName("script")[0];
        s.parentNode.insertBefore(bp, s);
    })();
</script>


<!-- Baidu Tongji -->
<script>
    // dynamic User by Hux
    var _baId = '{{ .Site.Params.ba_track_id }}';

    // Originial
    var _hmt = _hmt || [];
    (function() {
      var hm = document.createElement("script");
      hm.src = "//hm.baidu.com/hm.js?" + _baId;
      var s = document.getElementsByTagName("script")[0];
      s.parentNode.insertBefore(hm, s);
    })();
</script>
{{ end }}

{{ if .Site.GoogleAnalytics }}
{{ template "_internal/google_analytics_async.html" . }}
{{ end }}
